'use strict';

import Base from './base.js';

export default class extends Base {

  async addAction(){
    return this.display();
  }

  async signinAction(){
    let allParams = this.post();
    let resData = await this.model('account').loginUser(allParams);
    if(think.isEmpty(resData)){
      return this.fail('6001',this.config("error.E6001"),resData);
    }
    delete resData.usr_pwd;
    return this.success(resData);
  }
}